/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #4a4a4a;
    background: linear-gradient(135deg, #d4c5b9 0%, #b8a99a 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: #8b7d6b;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: #8b7d6b;
    background: linear-gradient(135deg, #c9b8a8, #a89688);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 125, 107, 0.3);
}

/* 主要内容区域 */
.main {
    margin-top: 80px;
}

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, rgba(201, 184, 168, 0.9), rgba(168, 150, 136, 0.9));
    color: white;
    text-align: center;
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="%23ffffff" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>') repeat;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease-out;
}

.hero-subtitle {
    font-size: 1.3rem;
    opacity: 0.9;
    animation: fadeInUp 1s ease-out 0.3s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 功能卡片区域 */
.features {
    padding: 6rem 0;
    background: rgba(255, 255, 255, 0.95);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 3rem;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.feature-card {
    background: white;
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(139, 125, 107, 0.1), transparent);
    transition: left 0.5s ease;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #8b7d6b;
    display: flex;
    justify-content: center;
    align-items: center;
}

.feature-icon img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.feature-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #8b7d6b;
}

.feature-desc {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.feature-arrow {
    font-size: 1.5rem;
    color: #8b7d6b;
    font-weight: bold;
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-arrow {
    transform: translateX(10px);
}

/* 关于区域 */
.about {
    padding: 6rem 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: #764ba2;
}

.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    color: #555;
}

/* 页面内容样式 */
.page-content {
    padding: 6rem 0;
    background: rgba(255, 255, 255, 0.95);
    min-height: calc(100vh - 160px);
}

.page-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #764ba2;
}

/* 美食卡片 */
.food-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.food-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.food-card:hover {
    transform: translateY(-5px);
}

.food-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(45deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
}

.food-info {
    padding: 1.5rem;
}

.food-name {
    font-size: 1.3rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    color: #333;
}

.food-desc {
    color: #666;
    line-height: 1.6;
}

/* 旅游景点样式 */
.attraction-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.attraction-name {
    font-size: 1.5rem;
    color: #8b7d6b;
    margin-bottom: 1rem;
}

.attraction-desc {
    color: #666;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.attraction-tips {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: 10px;
    border-left: 4px solid #8b7d6b;
}

/* 唐诗样式 */
.poetry-container {
    max-width: 800px;
    margin: 0 auto;
}

.poetry-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.poetry-title {
    font-size: 1.5rem;
    color: #8b7d6b;
    margin-bottom: 1rem;
}

.poetry-author {
    color: #888;
    margin-bottom: 1.5rem;
}

.poetry-content {
    font-size: 1.2rem;
    line-height: 2;
    color: #333;
    font-style: italic;
}

.chat-container {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.chat-messages {
    height: 300px;
    overflow-y: auto;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1rem;
    background: #f8f9fa;
}

.message {
    margin-bottom: 1rem;
    padding: 0.8rem;
    border-radius: 10px;
}

.user-message {
    background: #8b7d6b;
    color: white;
    margin-left: 20%;
}

.ai-message {
    background: #e9ecef;
    color: #333;
    margin-right: 20%;
}

.chat-input {
    display: flex;
    gap: 1rem;
}

.chat-input input {
    flex: 1;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 25px;
    font-size: 1rem;
}

.chat-input button {
    padding: 0.8rem 2rem;
    background: linear-gradient(135deg, #c9b8a8, #a89688);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.chat-input button:hover {
    transform: translateY(-2px);
}

/* 陕西话样式 */
.dialect-intro {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.audio-section {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.audio-item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-left: 4px solid #764ba2;
}

.audio-text {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: #333;
}

.audio-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.play-btn {
    background: linear-gradient(135deg, #c9b8a8, #a89688);
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.play-btn:hover {
    transform: scale(1.1);
}

.audio-progress {
    flex: 1;
    height: 6px;
    background: #eee;
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(135deg, #c9b8a8, #a89688);
    width: 0%;
    transition: width 0.3s ease;
}

/* 关于西安部分样式 */
.about {
    background: rgba(255, 255, 255, 0.95);
    padding: 4rem 0;
    margin: 2rem 0;
}

.section-title {
    font-size: 2.5rem;
    color: #2c2c2c;
    text-align: center;
    margin-bottom: 2rem;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}

.about-text {
    font-size: 1.2rem;
    line-height: 1.8;
    color: #1a1a1a;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-weight: 500;
    text-shadow: 0.5px 0.5px 1px rgba(0, 0, 0, 0.05);
}

/* 底部样式 */
.footer {
    background: rgba(0, 0, 0, 0.8);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: auto;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
    
    .nav-list {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-list a {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
        text-align: center;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        text-align: center;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0 1rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .food-grid, .attraction-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .chat-input {
        flex-direction: column;
        gap: 1rem;
    }
    
    .chat-input input {
        margin-bottom: 0;
    }
    
    .audio-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }
    
    .audio-item {
        padding: 1rem;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .section {
        padding: 2rem 0;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .feature-card h3 {
        font-size: 1.3rem;
    }
    
    .nav-list a {
        padding: 0.4rem 0.8rem;
        font-size: 0.8rem;
    }
    
    .chat-messages {
        max-height: 250px;
    }
    
    .audio-text {
        font-size: 1rem;
    }
    
    .play-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #764ba2;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}